package com.one.group.service;

import com.mybatisflex.core.service.IService;
import com.one.group.model.dto.PositionListDto;
import com.one.group.model.dto.PositionQueryDto;
import com.one.group.model.entity.Position;
import com.one.group.model.vo.PositionVo;

import java.util.List;

/**
 * @Author wanbo
 * @Date 2025/10/11 15:23
 */
public interface PositionService extends IService<Position> {

    /**
     * 获取职位树
     * @param positionQueryDto
     * @return
     */
    List<PositionVo> selectPositionTree(PositionQueryDto positionQueryDto);

    /**
     * 根据id查询岗位
     * @param id
     * @return
     */
    Position getPositionById(Long id);

    /**
     * 删除部门及其子部门
     * @param id
     * @return
     */
    boolean removePositionAndChild(Long id);

    List<PositionVo> selectPositionTreeByQuery(PositionQueryDto positionQueryDto);
}
